﻿namespace ACCOUNTING
{
    using ACCOUNTING.LVY.Business;
    using ACCOUNTING.My;
    using ACCOUNTING.My.Resources;
    using C1.Win.C1FlexGrid;
    using C1.Win.C1FlexGrid.Util.BaseControls;
    using Microsoft.VisualBasic;
    using Microsoft.VisualBasic.CompilerServices;
    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Data;
    using System.Diagnostics;
    using System.Drawing;
    using System.Runtime.CompilerServices;
    using System.Windows.Forms;

    [DesignerGenerated]
    public class Frm_TimDoiTuong : Form
    {
        private static List<WeakReference> __ENCList = new List<WeakReference>();
        [AccessedThroughProperty("CboKhuVuc")]
        private ComboBox _CboKhuVuc;
        [AccessedThroughProperty("CboLoaiDoiTuong")]
        private ComboBox _CboLoaiDoiTuong;
        [AccessedThroughProperty("CboLoaiKhachHang")]
        private ComboBox _CboLoaiKhachHang;
        [AccessedThroughProperty("CboNhanVienKinhDoanh")]
        private ComboBox _CboNhanVienKinhDoanh;
        [AccessedThroughProperty("CboTinhThanh")]
        private ComboBox _CboTinhThanh;
        [AccessedThroughProperty("CKHanThanhToan")]
        private CheckBox _CKHanThanhToan;
        [AccessedThroughProperty("CmdAddKhach")]
        private ToolStripMenuItem _CmdAddKhach;
        [AccessedThroughProperty("CmdAddNew")]
        private Button _CmdAddNew;
        [AccessedThroughProperty("CmdAddNhaCC")]
        private ToolStripMenuItem _CmdAddNhaCC;
        [AccessedThroughProperty("CmdAddNhanVien")]
        private ToolStripMenuItem _CmdAddNhanVien;
        [AccessedThroughProperty("CmdCancel")]
        private Button _CmdCancel;
        [AccessedThroughProperty("CmdNganHang")]
        private ToolStripMenuItem _CmdNganHang;
        [AccessedThroughProperty("CmdOK")]
        private Button _CmdOK;
        [AccessedThroughProperty("Label1")]
        private Label _Label1;
        [AccessedThroughProperty("Label15")]
        private Label _Label15;
        [AccessedThroughProperty("Label2")]
        private Label _Label2;
        [AccessedThroughProperty("Label37")]
        private Label _Label37;
        [AccessedThroughProperty("Label8")]
        private Label _Label8;
        [AccessedThroughProperty("NumHanThanhToan")]
        private NumericUpDown _NumHanThanhToan;
        [AccessedThroughProperty("Panel1")]
        private Panel _Panel1;
        [AccessedThroughProperty("Panel2")]
        private Panel _Panel2;
        [AccessedThroughProperty("PopupLoaiDT")]
        private ContextMenuStrip _PopupLoaiDT;
        [AccessedThroughProperty("TxtCode")]
        private TextBox _TxtCode;
        [AccessedThroughProperty("TxtName")]
        private TextBox _TxtName;
        [AccessedThroughProperty("TxtTaxCode")]
        private TextBox _TxtTaxCode;
        [AccessedThroughProperty("TxtTel")]
        private TextBox _TxtTel;
        [AccessedThroughProperty("TxtTimMaSoThue")]
        private TextBox _TxtTimMaSoThue;
        [AccessedThroughProperty("VSlist")]
        private C1.Win.C1FlexGrid.C1FlexGrid _VSlist;
        private IContainer components;
        private string mCode;
        private DataView mData;
        private DataTable mDataSource;
        private modGeneral.TypeObjects mLoaiDoiTuong;
        private string mValueReturn;
        private clsDMDoiTuong objDT;

        public Frm_TimDoiTuong()
        {
            base.Activated += new EventHandler(this.Frm_TimDoiTuong_Activated);
            base.KeyDown += new KeyEventHandler(this.Frm_TimDoiTuong_KeyDown);
            base.Load += new EventHandler(this.Frm_TimDoiTuong_Load);
            List<WeakReference> list = __ENCList;
            lock (list)
            {
                __ENCList.Add(new WeakReference(this));
            }
            this.mValueReturn = "";
            this.mCode = "";
            this.objDT = new clsDMDoiTuong();
            this.InitializeComponent();
        }

        private void CboKhuVuc_SelectedIndexChanged(object sender, EventArgs e)
        {
            if ((this.CboKhuVuc.SelectedIndex >= 0) && (this.mData != null))
            {
                this.LoadData();
            }
        }

        private void CboLoaiDoiTuong_SelectedIndexChanged(object sender, EventArgs e)
        {
            this.CboLoaiKhachHang.SelectedValue = "";
            this.CboKhuVuc.SelectedValue = "";
            if (this.mData != null)
            {
                string strLoaiDoiTuong = "";
                switch (this.CboLoaiDoiTuong.SelectedIndex)
                {
                    case 0:
                        strLoaiDoiTuong = "S";
                        break;

                    case 1:
                        strLoaiDoiTuong = "C";
                        break;

                    case 2:
                        strLoaiDoiTuong = "E";
                        break;

                    case 3:
                        strLoaiDoiTuong = "B";
                        break;
                }
                clsDMDoiTuong tuong = new clsDMDoiTuong();
                this.mData = new DataView(tuong.ShowList(strLoaiDoiTuong, ""));
                C1.Win.C1FlexGrid.C1FlexGrid vSlist = this.VSlist;
                vSlist.DataSource = this.mData;
                vSlist.Cols[0].Visible = false;
                vSlist[0, 1] = modGeneral.Tranlated("M\x00e3 đối tượng", "");
                vSlist[0, 2] = modGeneral.Tranlated("T\x00ean đối tượng", "");
                vSlist[0, 3] = modGeneral.Tranlated("Địa chỉ", "");
                vSlist[0, 4] = modGeneral.Tranlated("M\x00e3 số thuế", "");
                vSlist[0, 5] = modGeneral.Tranlated("Điện thoại", "");
                vSlist.Cols[1].Width = 90;
                vSlist.Cols[2].Width = 0xf5;
                vSlist.Cols[3].Width = 0xf5;
                vSlist.Cols[4].Width = 120;
                vSlist.Cols[5].Width = 50;
                vSlist = null;
            }
        }

        private void CboLoaiKhachHang_SelectedIndexChanged(object sender, EventArgs e)
        {
            if ((this.CboLoaiKhachHang.SelectedIndex >= 0) && (this.mData != null))
            {
                this.LoadData();
            }
        }

        private void CmdAddNew_Click(object sender, EventArgs e)
        {
            switch (this.CboLoaiDoiTuong.SelectedIndex)
            {
                case 0:
                    this.TxtCode.Text = "";
                    this.TxtName.Text = "";
                    MyProject.Forms.Frm_DMNhaCungCap.ShowDialog();
                    break;

                case 1:
                    this.TxtCode.Text = "";
                    this.TxtName.Text = "";
                    MyProject.Forms.Frm_KhachHang.cFrmKhoa = "";
                    MyProject.Forms.Frm_KhachHang.cFrmTask = "I";
                    MyProject.Forms.Frm_KhachHang.ShowDialog();
                    MyProject.Forms.Frm_KhachHang.objCall = this;
                    break;

                case 2:
                    this.TxtCode.Text = "";
                    this.TxtName.Text = "";
                    MyProject.Forms.Frm_DMNhanVien.ShowDialog();
                    break;

                case 3:
                    this.TxtCode.Text = "";
                    this.TxtName.Text = "";
                    MyProject.Forms.Frm_DMNganHang.ShowDialog();
                    break;
            }
            this.LoadData();
        }

        private void CmdCancel_Click(object sender, EventArgs e)
        {
            this.ValueReturn = "";
            this.TxtCode.Text = "";
            this.TxtName.Text = "";
            this.Dispose();
        }

        private void CmdOK_Click(object sender, EventArgs e)
        {
            if (this.VSlist.Rows.Count > 1)
            {
                this.mValueReturn = Conversions.ToString(Microsoft.VisualBasic.CompilerServices.Operators.ConcatenateObject(Microsoft.VisualBasic.CompilerServices.Operators.ConcatenateObject(Microsoft.VisualBasic.CompilerServices.Operators.ConcatenateObject(Microsoft.VisualBasic.CompilerServices.Operators.ConcatenateObject(this.VSlist[this.VSlist.Row, 0], "|"), this.VSlist[this.VSlist.Row, 1].ToString().Trim()), "|"), this.VSlist[this.VSlist.Row, 2].ToString().Trim()));
            }
            this.TxtCode.Text = "";
            this.TxtName.Text = "";
            this.Close();
        }

        [DebuggerNonUserCode]
        protected override void Dispose(bool disposing)
        {
            if (disposing && (this.components != null))
            {
                this.components.Dispose();
            }
            base.Dispose(disposing);
        }

        private void Frm_TimDoiTuong_Activated(object sender, EventArgs e)
        {
            this.TxtCode.Focus();
        }

        private void Frm_TimDoiTuong_KeyDown(object sender, KeyEventArgs e)
        {
            switch (e.KeyCode)
            {
                case Keys.Escape:
                    this.CmdCancel_Click(this.CmdCancel, e);
                    break;

                case Keys.F10:
                    this.CmdOK_Click(this.CmdOK, e);
                    break;

                case Keys.F8:
                    this.CmdAddNew_Click(this.CmdAddNew, e);
                    break;
            }
        }

        private void Frm_TimDoiTuong_Load(object sender, EventArgs e)
        {
            BuildComboModule.BuildCombo(this.CboKhuVuc, modGeneral.ListDanhMuc.KhuVuc, true, "", "");
            BuildComboModule.BuildCombo(this.CboLoaiKhachHang, modGeneral.ListDanhMuc.LoaiKhachHang, true, "", "");
            BuildComboModule.BuildCombo(this.CboTinhThanh, modGeneral.ListDanhMuc.TinhThanh, true, "", "");
            BuildComboModule.BuildCombo(this.CboNhanVienKinhDoanh, modGeneral.ListDanhMuc.DoiTuongNhanVien, true, "", "");
            this.CboKhuVuc.SelectedIndex = -1;
            this.CboLoaiKhachHang.SelectedIndex = -1;
            this.CboLoaiDoiTuong.Items.Clear();
            this.CboLoaiDoiTuong.Items.Add(modGeneral.Tranlated("Nh\x00e0 cung cấp", ""));
            this.CboLoaiDoiTuong.Items.Add(modGeneral.Tranlated("Kh\x00e1ch h\x00e0ng", ""));
            this.CboLoaiDoiTuong.Items.Add(modGeneral.Tranlated("Nh\x00e2n vi\x00ean", ""));
            this.CboLoaiDoiTuong.Items.Add(modGeneral.Tranlated("Ng\x00e2n h\x00e0ng", ""));
            this.CboLoaiKhachHang.Enabled = false;
            this.CboKhuVuc.Enabled = false;
            switch (this.mLoaiDoiTuong)
            {
                case modGeneral.TypeObjects.TatCa:
                    this.CboLoaiDoiTuong.SelectedIndex = -1;
                    break;

                case modGeneral.TypeObjects.NhaCungCap:
                    this.CboLoaiDoiTuong.SelectedIndex = 0;
                    break;

                case modGeneral.TypeObjects.KhachHang:
                    this.CboLoaiDoiTuong.SelectedIndex = 1;
                    this.CboLoaiKhachHang.Enabled = true;
                    this.CboKhuVuc.Enabled = true;
                    break;

                case modGeneral.TypeObjects.NhanVien:
                    this.CboLoaiDoiTuong.SelectedIndex = 2;
                    break;

                case modGeneral.TypeObjects.NganHang:
                    this.CboLoaiDoiTuong.SelectedIndex = 3;
                    break;
            }
            if (this.mDataSource != null)
            {
                this.mData = new DataView(this.mDataSource);
                C1.Win.C1FlexGrid.C1FlexGrid vSlist = this.VSlist;
                vSlist.DataSource = this.mData;
                vSlist.Cols[0].Visible = false;
                vSlist[0, 1] = modGeneral.Tranlated("M\x00e3 đối tượng", "");
                vSlist[0, 2] = modGeneral.Tranlated("T\x00ean đối tượng", "");
                vSlist[0, 3] = modGeneral.Tranlated("Địa chỉ", "");
                vSlist[0, 4] = modGeneral.Tranlated("M\x00e3 số thuế", "");
                vSlist[0, 5] = modGeneral.Tranlated("Điện thoại", "");
                vSlist.Cols[1].Width = 90;
                vSlist.Cols[2].Width = 0xf5;
                vSlist.Cols[3].Width = 0xf5;
                vSlist.Cols[4].Width = 120;
                vSlist.Cols[5].Width = 50;
                vSlist = null;
            }
            this.TxtCode.Text = this.mCode;
            this.TxtCode.SelectionStart = Strings.Len(this.TxtCode.Text.Trim());
            if (this.VSlist.Rows.Count > 1)
            {
                this.VSlist.Select(1, 1);
            }
            this.VSlist.Styles.Alternate.BackColor = ProfessionalColors.ToolStripGradientMiddle;
        }

        [DebuggerStepThrough]
        private void InitializeComponent()
        {
            this.components = new System.ComponentModel.Container();
            ComponentResourceManager manager = new ComponentResourceManager(typeof(Frm_TimDoiTuong));
            this.Panel1 = new Panel();
            this.CboTinhThanh = new ComboBox();
            this.Label37 = new Label();
            this.CboNhanVienKinhDoanh = new ComboBox();
            this.Label2 = new Label();
            this.NumHanThanhToan = new NumericUpDown();
            this.CKHanThanhToan = new CheckBox();
            this.CboKhuVuc = new ComboBox();
            this.Label8 = new Label();
            this.CboLoaiKhachHang = new ComboBox();
            this.Label15 = new Label();
            this.Label1 = new Label();
            this.CboLoaiDoiTuong = new ComboBox();
            this.CmdOK = new Button();
            this.TxtName = new TextBox();
            this.TxtCode = new TextBox();
            this.CmdCancel = new Button();
            this.VSlist = new C1.Win.C1FlexGrid.C1FlexGrid();
            this.Panel2 = new Panel();
            this.TxtTimMaSoThue = new TextBox();
            this.TxtTel = new TextBox();
            this.TxtTaxCode = new TextBox();
            this.CmdAddNew = new Button();
            this.PopupLoaiDT = new ContextMenuStrip(this.components);
            this.CmdAddKhach = new ToolStripMenuItem();
            this.CmdAddNhaCC = new ToolStripMenuItem();
            this.CmdAddNhanVien = new ToolStripMenuItem();
            this.CmdNganHang = new ToolStripMenuItem();
            this.Panel1.SuspendLayout();
            this.NumHanThanhToan.BeginInit();
            this.VSlist.BeginInit();
            this.Panel2.SuspendLayout();
            this.PopupLoaiDT.SuspendLayout();
            this.SuspendLayout();
            this.Panel1.BackColor = Color.AliceBlue;
            this.Panel1.BackgroundImage = ACCOUNTING.My.Resources.Resources.bgleft;
            this.Panel1.Controls.Add(this.CboTinhThanh);
            this.Panel1.Controls.Add(this.Label37);
            this.Panel1.Controls.Add(this.CboNhanVienKinhDoanh);
            this.Panel1.Controls.Add(this.Label2);
            this.Panel1.Controls.Add(this.NumHanThanhToan);
            this.Panel1.Controls.Add(this.CKHanThanhToan);
            this.Panel1.Controls.Add(this.CboKhuVuc);
            this.Panel1.Controls.Add(this.Label8);
            this.Panel1.Controls.Add(this.CboLoaiKhachHang);
            this.Panel1.Controls.Add(this.Label15);
            this.Panel1.Controls.Add(this.Label1);
            this.Panel1.Controls.Add(this.CboLoaiDoiTuong);
            this.Panel1.Dock = DockStyle.Top;
            Point point = new Point(0, 0);
            this.Panel1.Location = point;
            this.Panel1.Name = "Panel1";
            Size size = new Size(0x37e, 0x2a);
            this.Panel1.Size = size;
            this.Panel1.TabIndex = 0;
            this.CboTinhThanh.FormattingEnabled = true;
            point = new Point(0x1f2, 0x11);
            this.CboTinhThanh.Location = point;
            this.CboTinhThanh.Name = "CboTinhThanh";
            size = new Size(0x92, 0x15);
            this.CboTinhThanh.Size = size;
            this.CboTinhThanh.TabIndex = 0xab;
            this.Label37.AutoSize = true;
            this.Label37.BackColor = Color.Transparent;
            this.Label37.ForeColor = Color.Black;
            point = new Point(0x1ef, 3);
            this.Label37.Location = point;
            this.Label37.Name = "Label37";
            size = new Size(0x3a, 13);
            this.Label37.Size = size;
            this.Label37.TabIndex = 0xac;
            this.Label37.Text = "Tỉnh th\x00e0nh";
            this.CboNhanVienKinhDoanh.FormattingEnabled = true;
            point = new Point(0x2db, 0x12);
            this.CboNhanVienKinhDoanh.Location = point;
            this.CboNhanVienKinhDoanh.Name = "CboNhanVienKinhDoanh";
            size = new Size(0x9c, 0x15);
            this.CboNhanVienKinhDoanh.Size = size;
            this.CboNhanVienKinhDoanh.TabIndex = 0xa9;
            this.Label2.AutoSize = true;
            this.Label2.BackColor = Color.Transparent;
            this.Label2.ForeColor = Color.Black;
            point = new Point(0x2d8, 3);
            this.Label2.Location = point;
            this.Label2.Name = "Label2";
            size = new Size(0x70, 13);
            this.Label2.Size = size;
            this.Label2.TabIndex = 170;
            this.Label2.Text = "Nh\x00e2n vi\x00ean kinh doanh";
            point = new Point(650, 0x12);
            this.NumHanThanhToan.Location = point;
            this.NumHanThanhToan.Name = "NumHanThanhToan";
            size = new Size(0x4c, 20);
            this.NumHanThanhToan.Size = size;
            this.NumHanThanhToan.TabIndex = 0xa7;
            this.CKHanThanhToan.AutoSize = true;
            this.CKHanThanhToan.BackColor = Color.Transparent;
            point = new Point(650, 2);
            this.CKHanThanhToan.Location = point;
            this.CKHanThanhToan.Name = "CKHanThanhToan";
            size = new Size(0x51, 0x11);
            this.CKHanThanhToan.Size = size;
            this.CKHanThanhToan.TabIndex = 0xa8;
            this.CKHanThanhToan.Text = "Thanh to\x00e1n";
            this.CKHanThanhToan.UseVisualStyleBackColor = false;
            this.CboKhuVuc.FormattingEnabled = true;
            point = new Point(0x158, 0x11);
            this.CboKhuVuc.Location = point;
            this.CboKhuVuc.Name = "CboKhuVuc";
            size = new Size(0x93, 0x15);
            this.CboKhuVuc.Size = size;
            this.CboKhuVuc.TabIndex = 0x7e;
            this.Label8.AutoSize = true;
            this.Label8.BackColor = Color.Transparent;
            this.Label8.ForeColor = Color.Black;
            point = new Point(0x156, 2);
            this.Label8.Location = point;
            this.Label8.Name = "Label8";
            size = new Size(0x2f, 13);
            this.Label8.Size = size;
            this.Label8.TabIndex = 0x7f;
            this.Label8.Text = "Khu vực";
            this.CboLoaiKhachHang.FormattingEnabled = true;
            point = new Point(0xb2, 0x11);
            this.CboLoaiKhachHang.Location = point;
            this.CboLoaiKhachHang.Name = "CboLoaiKhachHang";
            size = new Size(160, 0x15);
            this.CboLoaiKhachHang.Size = size;
            this.CboLoaiKhachHang.TabIndex = 0x7c;
            this.Label15.AutoSize = true;
            this.Label15.BackColor = Color.Transparent;
            this.Label15.ForeColor = Color.Black;
            point = new Point(0xb1, 2);
            this.Label15.Location = point;
            this.Label15.Name = "Label15";
            size = new Size(50, 13);
            this.Label15.Size = size;
            this.Label15.TabIndex = 0x7d;
            this.Label15.Text = "Loại h\x00ecnh";
            this.Label1.AutoSize = true;
            this.Label1.BackColor = Color.Transparent;
            this.Label1.ForeColor = Color.Black;
            point = new Point(2, 2);
            this.Label1.Location = point;
            this.Label1.Name = "Label1";
            size = new Size(0x4b, 13);
            this.Label1.Size = size;
            this.Label1.TabIndex = 1;
            this.Label1.Text = "Loại đối tượng";
            this.CboLoaiDoiTuong.FormattingEnabled = true;
            point = new Point(4, 0x11);
            this.CboLoaiDoiTuong.Location = point;
            this.CboLoaiDoiTuong.Name = "CboLoaiDoiTuong";
            size = new Size(0xa8, 0x15);
            this.CboLoaiDoiTuong.Size = size;
            this.CboLoaiDoiTuong.TabIndex = 2;
            this.CmdOK.Image = (Image) manager.GetObject("CmdOK.Image");
            this.CmdOK.ImageAlign = ContentAlignment.MiddleLeft;
            point = new Point(0x2bf, 0x1d);
            this.CmdOK.Location = point;
            this.CmdOK.Name = "CmdOK";
            size = new Size(0x5e, 0x18);
            this.CmdOK.Size = size;
            this.CmdOK.TabIndex = 3;
            this.CmdOK.Text = "F10. &Chọn";
            this.CmdOK.UseVisualStyleBackColor = true;
            point = new Point(0x6f, 3);
            this.TxtName.Location = point;
            this.TxtName.Name = "TxtName";
            size = new Size(0x119, 20);
            this.TxtName.Size = size;
            this.TxtName.TabIndex = 1;
            point = new Point(2, 3);
            this.TxtCode.Location = point;
            this.TxtCode.Name = "TxtCode";
            size = new Size(0x69, 20);
            this.TxtCode.Size = size;
            this.TxtCode.TabIndex = 0;
            this.CmdCancel.Image = (Image) manager.GetObject("CmdCancel.Image");
            this.CmdCancel.ImageAlign = ContentAlignment.MiddleLeft;
            point = new Point(0x31f, 0x1d);
            this.CmdCancel.Location = point;
            this.CmdCancel.Name = "CmdCancel";
            size = new Size(0x58, 0x18);
            this.CmdCancel.Size = size;
            this.CmdCancel.TabIndex = 4;
            this.CmdCancel.Text = "Th&o\x00e1t";
            this.CmdCancel.UseVisualStyleBackColor = true;
            this.VSlist.AllowEditing = false;
            this.VSlist.BorderStyle = C1.Win.C1FlexGrid.Util.BaseControls.BorderStyleEnum.XpThemes;
            this.VSlist.ColumnInfo = manager.GetString("VSlist.ColumnInfo");
            this.VSlist.Dock = DockStyle.Fill;
            this.VSlist.ExtendLastCol = true;
            this.VSlist.FocusRect = FocusRectEnum.None;
            point = new Point(0, 0x2a);
            this.VSlist.Location = point;
            this.VSlist.Name = "VSlist";
            this.VSlist.Rows.Count = 1;
            this.VSlist.Rows.DefaultSize = 0x11;
            this.VSlist.SelectionMode = SelectionModeEnum.Row;
            size = new Size(0x37e, 0x1d5);
            this.VSlist.Size = size;
            this.VSlist.StyleInfo = manager.GetString("VSlist.StyleInfo");
            this.VSlist.TabIndex = 4;
            this.VSlist.VisualStyle = VisualStyle.Office2007Blue;
            this.Panel2.BackgroundImage = ACCOUNTING.My.Resources.Resources.bgleft;
            this.Panel2.Controls.Add(this.TxtTimMaSoThue);
            this.Panel2.Controls.Add(this.TxtTel);
            this.Panel2.Controls.Add(this.TxtTaxCode);
            this.Panel2.Controls.Add(this.CmdAddNew);
            this.Panel2.Controls.Add(this.CmdCancel);
            this.Panel2.Controls.Add(this.CmdOK);
            this.Panel2.Controls.Add(this.TxtName);
            this.Panel2.Controls.Add(this.TxtCode);
            this.Panel2.Dock = DockStyle.Bottom;
            point = new Point(0, 0x1ff);
            this.Panel2.Location = point;
            this.Panel2.Name = "Panel2";
            Padding padding = new Padding(2);
            this.Panel2.Padding = padding;
            size = new Size(0x37e, 0x3a);
            this.Panel2.Size = size;
            this.Panel2.TabIndex = 5;
            point = new Point(0x29f, 3);
            this.TxtTimMaSoThue.Location = point;
            this.TxtTimMaSoThue.Name = "TxtTimMaSoThue";
            size = new Size(0x57, 20);
            this.TxtTimMaSoThue.Size = size;
            this.TxtTimMaSoThue.TabIndex = 8;
            point = new Point(0x2fb, 3);
            this.TxtTel.Location = point;
            this.TxtTel.Name = "TxtTel";
            size = new Size(0x77, 20);
            this.TxtTel.Size = size;
            this.TxtTel.TabIndex = 7;
            point = new Point(0x18b, 3);
            this.TxtTaxCode.Location = point;
            this.TxtTaxCode.Name = "TxtTaxCode";
            size = new Size(0x10f, 20);
            this.TxtTaxCode.Size = size;
            this.TxtTaxCode.TabIndex = 6;
            this.CmdAddNew.Image = (Image) manager.GetObject("CmdAddNew.Image");
            this.CmdAddNew.ImageAlign = ContentAlignment.MiddleLeft;
            point = new Point(2, 30);
            this.CmdAddNew.Location = point;
            this.CmdAddNew.Name = "CmdAddNew";
            size = new Size(0x57, 0x17);
            this.CmdAddNew.Size = size;
            this.CmdAddNew.TabIndex = 5;
            this.CmdAddNew.Text = "F8.&Th\x00eam";
            this.CmdAddNew.UseVisualStyleBackColor = true;
            this.PopupLoaiDT.Items.AddRange(new ToolStripItem[] { this.CmdAddKhach, this.CmdAddNhaCC, this.CmdAddNhanVien, this.CmdNganHang });
            this.PopupLoaiDT.Name = "PopupLoaiDT";
            size = new Size(0x97, 0x5c);
            this.PopupLoaiDT.Size = size;
            this.CmdAddKhach.Name = "CmdAddKhach";
            size = new Size(150, 0x16);
            this.CmdAddKhach.Size = size;
            this.CmdAddKhach.Text = "Kh\x00e1ch h\x00e0ng";
            this.CmdAddNhaCC.Name = "CmdAddNhaCC";
            size = new Size(150, 0x16);
            this.CmdAddNhaCC.Size = size;
            this.CmdAddNhaCC.Text = "Nh\x00e0 cung cấp";
            this.CmdAddNhanVien.Name = "CmdAddNhanVien";
            size = new Size(150, 0x16);
            this.CmdAddNhanVien.Size = size;
            this.CmdAddNhanVien.Text = "Nh\x00e2n vi\x00ean";
            this.CmdNganHang.Name = "CmdNganHang";
            size = new Size(150, 0x16);
            this.CmdNganHang.Size = size;
            this.CmdNganHang.Text = "Ng\x00e2n h\x00e0ng";
            SizeF ef = new SizeF(6f, 13f);
            this.AutoScaleDimensions = ef;
            this.AutoScaleMode = AutoScaleMode.Font;
            size = new Size(0x37e, 0x239);
            this.ClientSize = size;
            this.ControlBox = false;
            this.Controls.Add(this.VSlist);
            this.Controls.Add(this.Panel2);
            this.Controls.Add(this.Panel1);
            this.FormBorderStyle = FormBorderStyle.FixedDialog;
            this.KeyPreview = true;
            this.Name = "Frm_TimDoiTuong";
            this.ShowIcon = false;
            this.ShowInTaskbar = false;
            this.StartPosition = FormStartPosition.CenterScreen;
            this.Text = "TIM DOI TUONG";
            this.Panel1.ResumeLayout(false);
            this.Panel1.PerformLayout();
            this.NumHanThanhToan.EndInit();
            this.VSlist.EndInit();
            this.Panel2.ResumeLayout(false);
            this.Panel2.PerformLayout();
            this.PopupLoaiDT.ResumeLayout(false);
            this.ResumeLayout(false);
        }

        public void LoadData()
        {
            string strConditions = "";
            if (LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboLoaiKhachHang.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() != "")
            {
                strConditions = " KhoaLoaiKhachHang = '" + LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboLoaiKhachHang.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() + "' ";
            }
            if (LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboKhuVuc.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() != "")
            {
                if (strConditions.Trim() != "")
                {
                    strConditions = strConditions + " AND KhoaKhuVuc = '" + LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboKhuVuc.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() + "'";
                }
                else
                {
                    strConditions = strConditions + " KhoaKhuVuc = '" + LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboKhuVuc.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() + "'";
                }
            }
            if (LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboNhanVienKinhDoanh.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() != "")
            {
                if (strConditions.Trim() != "")
                {
                    strConditions = strConditions + " AND KhoaNhanVienQuanLy = '" + LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboNhanVienKinhDoanh.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() + "'";
                }
                else
                {
                    strConditions = strConditions + " KhoaNhanVienQuanLy = '" + LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboNhanVienKinhDoanh.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() + "'";
                }
            }
            if (LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboTinhThanh.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() != "")
            {
                if (strConditions.Trim() != "")
                {
                    strConditions = strConditions + " AND KhoaNhanVienQuanLy = '" + LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboTinhThanh.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() + "'";
                }
                else
                {
                    strConditions = strConditions + " KhoaNhanVienQuanLy = '" + LVYModule.ReturnIfNull(RuntimeHelpers.GetObjectValue(this.CboTinhThanh.SelectedValue), "", modGeneral.TypeOfValue.String).ToString().Trim() + "'";
                }
            }
            string strLoaiDoiTuong = "";
            switch (this.CboLoaiDoiTuong.SelectedIndex)
            {
                case 0:
                    strLoaiDoiTuong = "S";
                    break;

                case 1:
                    strLoaiDoiTuong = "C";
                    break;

                case 2:
                    strLoaiDoiTuong = "E";
                    break;

                case 3:
                    strLoaiDoiTuong = "B";
                    break;
            }
            this.mData = new DataView(this.objDT.ShowList(strLoaiDoiTuong, strConditions));
            this.VSlist.DataSource = this.mData;
            C1.Win.C1FlexGrid.C1FlexGrid vSlist = this.VSlist;
            vSlist.Cols[0].Visible = false;
            vSlist.Cols[1].Width = 110;
            vSlist.Cols[2].Width = 290;
            vSlist.Cols[3].Width = 280;
            vSlist.Cols[4].Width = 120;
            vSlist.Cols[5].Width = 50;
            vSlist[0, 1] = modGeneral.Tranlated("M\x00e3 đối tượng", "");
            vSlist[0, 2] = modGeneral.Tranlated("T\x00ean đối tượng", "");
            vSlist[0, 3] = modGeneral.Tranlated("Địa chỉ", "");
            vSlist[0, 4] = modGeneral.Tranlated("M\x00e3 số thuế", "");
            vSlist[0, 5] = modGeneral.Tranlated("Điện thoại", "");
            vSlist = null;
        }

        public void SearchCode(string strCode)
        {
            string str = "";
            str = "Ma LIKE '" + strCode + "%'";
            this.mData.RowFilter = str;
            if (this.VSlist.Rows.Count != 1)
            {
                this.VSlist.Select(1, 0, 1, this.VSlist.Cols.Count - 1);
            }
            C1.Win.C1FlexGrid.C1FlexGrid vSlist = this.VSlist;
            vSlist.Cols[0].Visible = false;
            vSlist.Cols[1].Width = 110;
            vSlist.Cols[2].Width = 290;
            vSlist.Cols[3].Width = 280;
            vSlist.Cols[4].Width = 120;
            vSlist.Cols[5].Width = 50;
            vSlist = null;
        }

        public void SearchDiaChi(string strDiaChi)
        {
            string str = "";
            str = " DiaChi LIKE '%" + strDiaChi + "%'";
            this.mData.RowFilter = str;
            if (this.VSlist.Rows.Count != 1)
            {
                this.VSlist.Select(1, 0, 1, this.VSlist.Cols.Count - 1);
            }
            C1.Win.C1FlexGrid.C1FlexGrid vSlist = this.VSlist;
            vSlist.Cols[0].Visible = false;
            vSlist.Cols[1].Width = 110;
            vSlist.Cols[2].Width = 290;
            vSlist.Cols[3].Width = 280;
            vSlist.Cols[4].Width = 120;
            vSlist.Cols[5].Width = 50;
            vSlist = null;
        }

        public void SearchDienThoai(string strDienThoai)
        {
            string str = "";
            str = " DienThoai LIKE '%" + strDienThoai + "%'";
            this.mData.RowFilter = str;
            if (this.VSlist.Rows.Count != 1)
            {
                this.VSlist.Select(1, 0, 1, this.VSlist.Cols.Count - 1);
            }
            C1.Win.C1FlexGrid.C1FlexGrid vSlist = this.VSlist;
            vSlist.Cols[0].Visible = false;
            vSlist.Cols[1].Width = 110;
            vSlist.Cols[2].Width = 290;
            vSlist.Cols[3].Width = 280;
            vSlist.Cols[4].Width = 120;
            vSlist.Cols[5].Width = 50;
            vSlist = null;
        }

        public void SearchMaSoThue(string strMaSoThue)
        {
            string str = "";
            str = " MaSoThue LIKE '%" + strMaSoThue + "%'";
            this.mData.RowFilter = str;
            if (this.VSlist.Rows.Count != 1)
            {
                this.VSlist.Select(1, 0, 1, this.VSlist.Cols.Count - 1);
            }
            C1.Win.C1FlexGrid.C1FlexGrid vSlist = this.VSlist;
            vSlist.Cols[0].Visible = false;
            vSlist.Cols[1].Width = 110;
            vSlist.Cols[2].Width = 290;
            vSlist.Cols[3].Width = 280;
            vSlist.Cols[4].Width = 120;
            vSlist.Cols[5].Width = 50;
            vSlist = null;
        }

        public void SearchName(string strName)
        {
            string str = "";
            str = "Ten LIKE '%" + strName + "%'";
            this.mData.RowFilter = str;
            if (this.VSlist.Rows.Count != 1)
            {
                this.VSlist.Select(1, 0, 1, this.VSlist.Cols.Count - 1);
            }
            C1.Win.C1FlexGrid.C1FlexGrid vSlist = this.VSlist;
            vSlist.Cols[0].Visible = false;
            vSlist.Cols[1].Width = 110;
            vSlist.Cols[2].Width = 290;
            vSlist.Cols[3].Width = 280;
            vSlist.Cols[4].Width = 120;
            vSlist.Cols[5].Width = 50;
            vSlist = null;
        }

        private void TxtCode_KeyDown(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Return)
            {
                this.CmdOK_Click(RuntimeHelpers.GetObjectValue(sender), e);
            }
            if (e.KeyCode == Keys.Down)
            {
                if (this.VSlist.Row < (this.VSlist.Rows.Count - 1))
                {
                    this.VSlist.Select(this.VSlist.Row + 1, 1);
                }
                e.SuppressKeyPress = true;
            }
            if (e.KeyCode == Keys.Up)
            {
                if (this.VSlist.Row > 1)
                {
                    this.VSlist.Select(this.VSlist.Row - 1, 1);
                }
                e.SuppressKeyPress = true;
            }
        }

        private void TxtCode_TextChanged(object sender, EventArgs e)
        {
            this.SearchCode(this.TxtCode.Text);
        }

        private void TxtName_KeyDown(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Return)
            {
                this.CmdOK_Click(RuntimeHelpers.GetObjectValue(sender), e);
            }
            if (e.KeyCode == Keys.Down)
            {
                if (this.VSlist.Row < (this.VSlist.Rows.Count - 1))
                {
                    this.VSlist.Select(this.VSlist.Row + 1, 1);
                }
                e.SuppressKeyPress = true;
            }
            if (e.KeyCode == Keys.Up)
            {
                if (this.VSlist.Row > 1)
                {
                    this.VSlist.Select(this.VSlist.Row - 1, 1);
                }
                e.SuppressKeyPress = true;
            }
        }

        private void TxtName_TextChanged(object sender, EventArgs e)
        {
            this.SearchName(this.TxtName.Text);
        }

        private void TxtTaxCode_TextChanged(object sender, EventArgs e)
        {
            this.SearchDiaChi(this.TxtTaxCode.Text);
        }

        private void TxtTel_TextChanged(object sender, EventArgs e)
        {
            this.SearchDienThoai(this.TxtTel.Text);
        }

        private void TxtTimMaSoThue_TextChanged(object sender, EventArgs e)
        {
            this.SearchMaSoThue(this.TxtTimMaSoThue.Text);
        }

        private void VSlist_Click(object sender, EventArgs e)
        {
        }

        private void VSlist_DoubleClick(object sender, EventArgs e)
        {
            this.CmdOK_Click(RuntimeHelpers.GetObjectValue(sender), e);
        }

        internal virtual ComboBox CboKhuVuc
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CboKhuVuc;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CboKhuVuc_SelectedIndexChanged);
                if (this._CboKhuVuc != null)
                {
                    this._CboKhuVuc.SelectedIndexChanged -= handler;
                }
                this._CboKhuVuc = value;
                if (this._CboKhuVuc != null)
                {
                    this._CboKhuVuc.SelectedIndexChanged += handler;
                }
            }
        }

        internal virtual ComboBox CboLoaiDoiTuong
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CboLoaiDoiTuong;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CboLoaiDoiTuong_SelectedIndexChanged);
                if (this._CboLoaiDoiTuong != null)
                {
                    this._CboLoaiDoiTuong.SelectedIndexChanged -= handler;
                }
                this._CboLoaiDoiTuong = value;
                if (this._CboLoaiDoiTuong != null)
                {
                    this._CboLoaiDoiTuong.SelectedIndexChanged += handler;
                }
            }
        }

        internal virtual ComboBox CboLoaiKhachHang
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CboLoaiKhachHang;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CboLoaiKhachHang_SelectedIndexChanged);
                if (this._CboLoaiKhachHang != null)
                {
                    this._CboLoaiKhachHang.SelectedIndexChanged -= handler;
                }
                this._CboLoaiKhachHang = value;
                if (this._CboLoaiKhachHang != null)
                {
                    this._CboLoaiKhachHang.SelectedIndexChanged += handler;
                }
            }
        }

        internal virtual ComboBox CboNhanVienKinhDoanh
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CboNhanVienKinhDoanh;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._CboNhanVienKinhDoanh = value;
            }
        }

        internal virtual ComboBox CboTinhThanh
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CboTinhThanh;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._CboTinhThanh = value;
            }
        }

        internal virtual CheckBox CKHanThanhToan
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CKHanThanhToan;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._CKHanThanhToan = value;
            }
        }

        internal virtual ToolStripMenuItem CmdAddKhach
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdAddKhach;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._CmdAddKhach = value;
            }
        }

        internal virtual Button CmdAddNew
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdAddNew;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdAddNew_Click);
                if (this._CmdAddNew != null)
                {
                    this._CmdAddNew.Click -= handler;
                }
                this._CmdAddNew = value;
                if (this._CmdAddNew != null)
                {
                    this._CmdAddNew.Click += handler;
                }
            }
        }

        internal virtual ToolStripMenuItem CmdAddNhaCC
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdAddNhaCC;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._CmdAddNhaCC = value;
            }
        }

        internal virtual ToolStripMenuItem CmdAddNhanVien
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdAddNhanVien;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._CmdAddNhanVien = value;
            }
        }

        internal virtual Button CmdCancel
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdCancel;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdCancel_Click);
                if (this._CmdCancel != null)
                {
                    this._CmdCancel.Click -= handler;
                }
                this._CmdCancel = value;
                if (this._CmdCancel != null)
                {
                    this._CmdCancel.Click += handler;
                }
            }
        }

        internal virtual ToolStripMenuItem CmdNganHang
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdNganHang;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._CmdNganHang = value;
            }
        }

        internal virtual Button CmdOK
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdOK;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdOK_Click);
                if (this._CmdOK != null)
                {
                    this._CmdOK.Click -= handler;
                }
                this._CmdOK = value;
                if (this._CmdOK != null)
                {
                    this._CmdOK.Click += handler;
                }
            }
        }

        public string Code
        {
            get
            {
                return this.mCode;
            }
            set
            {
                this.mCode = value;
            }
        }

        internal virtual Label Label1
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label1;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label1 = value;
            }
        }

        internal virtual Label Label15
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label15;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label15 = value;
            }
        }

        internal virtual Label Label2
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label2;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label2 = value;
            }
        }

        internal virtual Label Label37
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label37;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label37 = value;
            }
        }

        internal virtual Label Label8
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label8;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label8 = value;
            }
        }

        public modGeneral.TypeObjects LoaiDoiTuong
        {
            get
            {
                return this.mLoaiDoiTuong;
            }
            set
            {
                this.mLoaiDoiTuong = value;
            }
        }

        internal virtual NumericUpDown NumHanThanhToan
        {
            [DebuggerNonUserCode]
            get
            {
                return this._NumHanThanhToan;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._NumHanThanhToan = value;
            }
        }

        internal virtual Panel Panel1
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Panel1;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Panel1 = value;
            }
        }

        internal virtual Panel Panel2
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Panel2;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Panel2 = value;
            }
        }

        internal virtual ContextMenuStrip PopupLoaiDT
        {
            [DebuggerNonUserCode]
            get
            {
                return this._PopupLoaiDT;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._PopupLoaiDT = value;
            }
        }

        public DataTable SourceTable
        {
            get
            {
                return this.mDataSource;
            }
            set
            {
                this.mDataSource = value;
            }
        }

        internal virtual TextBox TxtCode
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtCode;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.TxtCode_TextChanged);
                KeyEventHandler handler2 = new KeyEventHandler(this.TxtCode_KeyDown);
                if (this._TxtCode != null)
                {
                    this._TxtCode.TextChanged -= handler;
                    this._TxtCode.KeyDown -= handler2;
                }
                this._TxtCode = value;
                if (this._TxtCode != null)
                {
                    this._TxtCode.TextChanged += handler;
                    this._TxtCode.KeyDown += handler2;
                }
            }
        }

        internal virtual TextBox TxtName
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtName;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.TxtName_TextChanged);
                KeyEventHandler handler2 = new KeyEventHandler(this.TxtName_KeyDown);
                if (this._TxtName != null)
                {
                    this._TxtName.TextChanged -= handler;
                    this._TxtName.KeyDown -= handler2;
                }
                this._TxtName = value;
                if (this._TxtName != null)
                {
                    this._TxtName.TextChanged += handler;
                    this._TxtName.KeyDown += handler2;
                }
            }
        }

        internal virtual TextBox TxtTaxCode
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtTaxCode;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.TxtTaxCode_TextChanged);
                if (this._TxtTaxCode != null)
                {
                    this._TxtTaxCode.TextChanged -= handler;
                }
                this._TxtTaxCode = value;
                if (this._TxtTaxCode != null)
                {
                    this._TxtTaxCode.TextChanged += handler;
                }
            }
        }

        internal virtual TextBox TxtTel
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtTel;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.TxtTel_TextChanged);
                if (this._TxtTel != null)
                {
                    this._TxtTel.TextChanged -= handler;
                }
                this._TxtTel = value;
                if (this._TxtTel != null)
                {
                    this._TxtTel.TextChanged += handler;
                }
            }
        }

        internal virtual TextBox TxtTimMaSoThue
        {
            [DebuggerNonUserCode]
            get
            {
                return this._TxtTimMaSoThue;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.TxtTimMaSoThue_TextChanged);
                if (this._TxtTimMaSoThue != null)
                {
                    this._TxtTimMaSoThue.TextChanged -= handler;
                }
                this._TxtTimMaSoThue = value;
                if (this._TxtTimMaSoThue != null)
                {
                    this._TxtTimMaSoThue.TextChanged += handler;
                }
            }
        }

        public string ValueReturn
        {
            get
            {
                return this.mValueReturn;
            }
            set
            {
                this.mValueReturn = value;
            }
        }

        internal virtual C1.Win.C1FlexGrid.C1FlexGrid VSlist
        {
            [DebuggerNonUserCode]
            get
            {
                return this._VSlist;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.VSlist_Click);
                EventHandler handler2 = new EventHandler(this.VSlist_DoubleClick);
                if (this._VSlist != null)
                {
                    this._VSlist.Click -= handler;
                    this._VSlist.DoubleClick -= handler2;
                }
                this._VSlist = value;
                if (this._VSlist != null)
                {
                    this._VSlist.Click += handler;
                    this._VSlist.DoubleClick += handler2;
                }
            }
        }
    }
}

